if ($msg =~ /^register (.*)/) {
  my ($asku, $askp) = split(/ /, $1);
  
  if (exists $users->{$asku}) {
    $self->sendMessage("Sorry, that username is taken!");
  }
  else {
    $users->{$asku}->{password} = md5($askp);
    $users->{$asku}->{credits} = 50;
    $self->sendMessage("You now have an account. Use the login command to login!");
  }
}